package com.eol.web;

import com.eol.common.utils.SpringContextHolder;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.security.servlet.SecurityAutoConfiguration;
import org.springframework.context.annotation.Bean;
import org.springframework.transaction.annotation.EnableTransactionManagement;
import tk.mybatis.spring.annotation.MapperScan;

/**
 * Created with IntelliJ IDEA.
 * User: liulinhui
 * Date: 2020/5/8
 * Time: 11:17 PM
 * Description: WebApplication
 */
@SpringBootApplication
        (
                scanBasePackages = "com.eol",
                exclude = {SecurityAutoConfiguration.class}
        )
@EnableTransactionManagement
@MapperScan("com.eol.mapper.business")
public class WebApplication {

    public static void main(String[] args) {
        SpringApplication.run(WebApplication.class, args);
    }

    @Bean
    public SpringContextHolder springContextHolder() {
        return new SpringContextHolder();
    }
}
